package ch06;

/**
 * Created by HaoChen on 2016/3/27.
 */
public class RPG3
{
    public static void main(String[] args)
    {
        SwordsMan3 swordsMan = new SwordsMan3();
        swordsMan.setName("Justin");
        swordsMan.setLevel(1);
        swordsMan.setBlood(200);

        Magician magician = new Magician();
        magician.setName("Monica");
        magician.setLevel(1);
        magician.setBlood(100);

        drawFight(swordsMan);
        drawFight(magician);

    }
    static void drawFight(Role3 role)
    {
        System.out.print(role.getName());
        role.fight();
    }
}